package com.yizhang.controller;


import com.yizhang.config.RobotProperties;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/customer")
public class RobotController {

    @Autowired
    private RobotProperties robotProperties;

    @GetMapping("/hello")
    public String hello(){
        return "hello," + robotProperties.getName() + " 你的年龄是:" + robotProperties.getAge() + "岁";
    }
}
